package ru.amse.tsyganov.jumleditor.graphicaleditor;

import ru.amse.tsyganov.jumleditor.model.FinalState;
import ru.amse.tsyganov.jumleditor.model.State;
import ru.amse.tsyganov.jumleditor.view.FinalStateView;
import ru.amse.tsyganov.jumleditor.view.StateView;

/*package*/ class AddFinalStateMode extends AddStateMode {

	public AddFinalStateMode(GraphicalEditor graphicalEditor) {
		super(graphicalEditor);
	}

	@Override
	public StateView<? extends State> createNewState() {
		FinalState state = new FinalState();
		StateView<? extends State> newStateView = 
			new FinalStateView<FinalState>(state, getEditor().getActivityGraphView());
		
		return newStateView;
	}

}
